var express = require('express');
var app = express();
var render = require('./compile');

app.route('/book')
	.get(function(req, res) {
		
	})
	.post(function(req, res) {
		res.send('Post book');
	});
app.get('/d/:username',function(req,res) {
	var html = render('home',{user:{name:req.params.username}});
	res.end(html);
});
var server = app.listen(3030,function(){
	console.log('服务器启动');
}); 